<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<title></title>
	<link rel="stylesheet" type="text/css" href="http://localhost/YouHuoShop/Static/Index/style/bootstrap-3.3.5-dist/css/bootstrap.min.css"/>
	<link rel="stylesheet" type="text/css" href="http://localhost/YouHuoShop/Static/Index/style/foot.css"/>
	<link rel="stylesheet" type="text/css" href="http://localhost/YouHuoShop/Static/Index/style/list.css"/>
	<script src="http://localhost/YouHuoShop/Static/Index/js/jquery-1.7.2.min.js" type="text/javascript" charset="utf-8"></script>
	<script src="http://localhost/YouHuoShop/Static/Index/js/list.js" type="text/javascript" charset="utf-8"></script>
	<script src="http://localhost/YouHuoShop/Static/Index/js/common.js" type="text/javascript" charset="utf-8"></script>
</head>
<body>
<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>

<link rel="stylesheet" type="text/css" href="http://localhost/YouHuoShop/Static/Index/style/topNav.css"/>

<!---------------顶部logo区域开始--------------->
<div id="topLogo">
</div>
<!---------------顶部logo结束------------------->
<a href="#memBox" id="toTop"><span class="glyphicon glyphicon-menu-up"></span></a>

<!---------------顶部会员消息区域开始------------>
<div id="memBox">
	<div id="mem">
		<div class="left">
			<a href="<?php echo U('Index/index');?>"><p>YOHO!有货</p></a>
		</div>
		<div class="right">
			<ul>
				<p>
					    <?php if(isset($hd['session']['uid'])&&isset($hd['session']['uname'])){ ?>
						<a href="<?php echo U('User/index',array('uid'=>$_SESSION['uid']));?>">Hi~<?php echo $hd['session']['uname'];?></a>
						<a href="<?php echo U('Member/out');?>">退出</a>
					<?php }else{ ?>
						<a href="<?php echo U('Member/login');?>">[请登录]</a>
						<a href="<?php echo U('Member/register');?>">[免费注册] </a>|
					<?php } ?>
				</p>
				<li><a href="">MY有货</a>|</li>
				<li><a href="">我的订单</a>|</li>
				<li><a href="">我的收藏</a>|</li>
				<li><a href="">消息</a>|</li>
				<li class="mob">
					<a href="">手机版</a>
					<div class="code">
						<div class="codeImg"></div>
						<h3 class="codeWords">扫描二维码</h3>
						<h3 class="codeWords">下载有货手机客户端</h3>
						<a href="">更多客户端下载</a>
					</div>
				</li>
			</ul>
		</div>
	</div>
</div>
<!---------------顶部会员消息区域结束------------>


<!---------------顶部导航搜索区域开始 ----------->

<div id="navSearchBox">
	<!--导航、二级菜单开始-->
	<div class="navSearch">
		<ul class="navCate">
			<!--<li class="checked">
				<p><a class="titleC" href="">男生</a></p>
				<p><a class="titleE" href="">BOYS</a></p>
			</li>
			<li>
				<p><a class="titleC" href="">女生</a></p>
				<p><a class="titleE" href="">GIRLS</a></p>
			</li>
			<li>
				<p><a class="titleC" href="">创意生活</a></p>
				<p><a class="titleE" href="">LIFE STYLE</a></p>
			</li>-->
		</ul>
	</div>	
	<div class="navBg">
		<div class="nav show">
			<ul class="navCate">
				<li class="fst"><a class="Cate" href="">新品到着</a></li>
				<li><a class="Cate" href="">品牌一览</a></li>
				<?php foreach ($navCate as $tk=>$t){?>
					<li>
						<a class="Cate" href="<?php echo U('list/index',array('cid'=>$tk));?>"><?php echo $t['cname'];?></a>
						<div class="cateBox">
							<div class="cateAll">
								<div class="sonCate ">
									<?php $i=0; ?>
									<?php foreach ($t['son'] as $ck=>$c){?>
										<p class="cateTitle"><a href="<?php echo U('list/index',array('cid'=>$c['cid']));?>"><?php echo $c['cname'];?></a></p>
										<?php $j=0;?>
										<?php foreach ($c['sec'] as $sk=>$s){?>
											<!--标签加class="hot"变红-->
											<p><a     <?php if($sk%3==0){ ?>class="hot" <?php } ?>href="<?php echo U('list/index',array('cid'=>$s['cid']));?>"><?php echo $s['cname'];?></a></p>
											<?php $i++; ?>
										    <?php if($i%7==0){ ?>
											</div>
											<div class="sonCate noF">
										<?php } ?>
										<?php
											$j++;
											if($j>3){ break; }
										?>
										<?php }?>
									<?php }?>
								</div>
								
								<div class="cateImg">
									<img src="http://localhost/YouHuoShop/Static/Index/images/cate.jpg" alt="" />
									<a href="">IN季新品全面开售</a>
								</div>
							</div>
						</div>
					</li>
				<?php }?>
			</ul>
		</div>
	</div>
	<!--导航、二级菜单结束-->
	
	<!--图片logo-->
	<a class="logo" href="http://localhost/YouHuoShop"><img src="http://localhost/YouHuoShop/Static/Index/images/logo_e.png" alt="" /></a>
	<!--搜索区域-->
	<div class="search">
		<form action="" method="post">
			<input class="words" name="words" type="text" />
			<input type="submit" class="sub" value="" />
		</form>
		<!--购物车-->
		<div class="car">
			<a href="" class=""><img src="http://localhost/YouHuoShop/Static/Index/images/car.png"/></a>
			<a href="" class="carBg">    <?php if(isset($_SESSION['cart'])){ ?><?php echo $_SESSION['cart']['total_rows'];?><?php }else{ ?>0<?php } ?></a>
		</div>
		<div class="shopping">
			<a href="javascript:;" class="close"><span class=" glyphicon glyphicon-remove"></span></a>
			    <?php if(!isset($_SESSION['cart'])){ ?>
				<ul class="emptyCar">
					<img src="http://localhost/YouHuoShop/Static/Index/images/car/empty_car.png" alt="" />
					<h3>您的购物车暂无商品</h3>
				</ul>
			<?php } ?>
			<!--购物车内的商品是li-->
				<ul>
			<?php foreach ($_SESSION['cart']['goods'] as $k=>$g){?>
					<li>
						<img src="http://localhost/YouHuoShop/<?php echo $g['thumb'];?>" alt="" />
						<a class="goodsName" href=""><?php echo mb_substr($g['name'],0,22,'utf-8');?></a>
						<p>
							<?php foreach ($g['options'] as $ok=>$o){?>
								<span class="size"><?php echo $ok;?>：<?php echo $o;?></span>
							<?php }?>
						</p>
						<span class="price">￥<?php echo $g['price'];?> * <?php echo $g['num'];?></span>
						<a href="" class="del">删除</a>
					</li>
			<?php }?>
					<a href="<?php echo U('confirmOrder/index');?>" class="toShopping">去购物车结算</a>
				</ul>
		</div>
	</div>
</div>
<!---------------顶部导航搜索区域结束 ----------->

<!---------------面包屑导航区域开始 ------------->
<div id="bread">
	<a href="http://localhost/YouHuoShop"> BOYS首页 </a>
	        <?php
        //初始化
        $hd['list']['b'] = array(
            'first' => false,
            'last'  => false,
            'total' => 0,
            'index' => 0
        );
        if (empty($bread)) {
            echo '';
        } else {
            $listId = 0;
            $listShowNum=0;
            $listNextId=0;
            foreach ($bread as $b) {
                //开始值
                if ($listId<0) {
                    $listId++;
                    continue;
                }
                //步长
                if($listId!=$listNextId){$listId++;continue;}
                //显示条数
                if($listShowNum>=100)break;
                //第几个值
                $hd['list'][b]['index']++;
                //第1个值
                $hd['list'][b]['first']=($listId == 0);
                //最后一个值
                $hd['list'][b]['last']= (count($bread)-1 <= $listId);
                //总数
                $hd['list'][b]['total']++;
                //增加数
                $listId++;
                $listShowNum++;
                $listNextId+=1
                ?>
		    <?php if($hd['list']['b']['last']){ ?>
			<span>></span>
			<span class="last"><?php echo $b['cname'];?></span>
		<?php }else{ ?>	
			<span>></span>
			<a href="<?php echo U('List/index',array('cid'=>$b['cid']));?>"><?php echo $b['cname'];?></a>
		<?php } ?>
	<?php }}?>

</div>
<!---------------面包屑导航区域结束 ------------->

<!---------------商品展示区域开始 --------------->
<div id="showGoodsBox">
	<!--左侧分类列表区域-->
	<div class="leftCate">
		<ul class="list">
			<li class="allCate cate">全部品类<!--<span class="num">31894</span>--></li>
			<?php $i=0;$j=0 ?>
			<?php foreach ($navCate as $tk=>$t){?>
				<?php foreach ($t['son'] as $sk=>$s){?>
				<li class="topCate">
					<i><span class="glyphicon glyphicon-play"></span></i>
					<span class="cate"><?php echo $s['cname'];?></span>
					<!--<span class="num">12654</span>-->
					<div class="sonCate"     <?php if(isset($_GET['jsT'])&&$i==$_GET['jsT']){ ?>style="display:block;"<?php } ?> >
						<?php foreach ($s['sec'] as $ck=>$c){?>
							<a class="checkA     <?php if(isset($_GET['jsA'])&&$j==$_GET['jsA']){ ?>checked<?php } ?>" href="<?php echo U('index',array('cid'=>$c['cid'],'jsT'=>$i,'jsA'=>$j));?>"><?php echo mb_substr($c['cname'],0,8,'utf-8');?><!--<span class="num">12654</span>--></a>
							<?php $j++; ?>
						<?php }?>
						
					</div>
				</li>
				<?php $i++; ?>
				<?php }?>
			<?php }?>
			<!--<li class="topCate">
				<i><span class="glyphicon glyphicon-play"></span></i>
				<span class="cate">裤子</span>
				<span class="num">10354</span>
				<div class="sonCate">
					<a href="javascript:;">全部裤子<span class="num">12654</span></a>
					<a href="javascript:;">西裤<span class="num">1254</span></a>
					<a href="javascript:;">休闲裤<span class="num">154</span></a>
					<a href="javascript:;">短裤<span class="num">552</span></a>
					<a href="javascript:;">牛仔裤<span class="num">2654</span></a>
					<a href="javascript:;">运动裤<span class="num">1054</span></a>
					<a href="javascript:;">夹克<span class="num">126</span></a>
					<a href="javascript:;">西装<span class="num">14</span></a>
				</div>
			</li>-->
		</ul>
	</div>
	<!--左侧分类列表区域结束-->
	
	<!--右侧商品展示区域开始-->
	<div class="rightGoods">
		<div class="topShow">
			<div class="content">
				<h1>POLO衫</h1>
				<h5>POLO SHIRT</h5>
				<p>
					如果说T-Shirt的发展是屌丝逆袭的话，那么Polo Shirt绝对是高富帅。其来自7次大满贯冠军René Lacoste及其同名品牌，鳄鱼的LOGO同样来自其职场上的外号。当lacoste将他的服装推向市场时还叫做网球衫，但马球运动员们马上意识到这样的服装比他们穿的更适合，1972年，Ralph Lauren推出经典的马球POLO Shirt款式，参考“网球衫”胸前的鳄鱼而设计了马球的刺绣款式，并在后来大获成功。
				</p>
			</div>
			<div class="conImg">
				<!--展示图片-->
				<a href=""><img src="http://localhost/YouHuoShop/Static/Index/images/listConImg.jpg" alt="" /></a>
			</div>
		</div>
		
		<!--商品筛选区域开始-->
		<div class="filter">
			<div class="filted">
				<span>已选条件：</span>
				<a href="<?php echo U('index',array('cid'=>$_GET['cid']));?>" class="clean">清空筛选条件</a>
			</div>
			<?php
				$i=0;
			?>
			<?php foreach ($filterData as $tk=>$t){?>
				<?php
					$temp=$pram;
				?>
				<div class="filCase barnd fil">
					<span class="caseTitle"><?php echo $tk;?>：</span>
					<div class="op ">
						<?php
							$temp[$i]=0;
						?>
						<a href="<?php echo U('index',array('cid'=>$_GET['cid'],'pram'=>implode('_',$temp)));?>" class="caseBox     <?php if($pram[$i]==0){ ?>checked<?php } ?>">
							<span class="rect"><i>√</i></span>
							<span class="case">不限</span>
						</a>
						<?php foreach ($t as $ak=>$a){?>
							<?php
								if($pram[$i]==$a['gaid']){
									$temp[$i]=0;
								}else{
									$temp[$i]=$a['gaid'];							    
								}
							?>
							<a href="<?php echo U('index',array('cid'=>$_GET['cid'],'pram'=>implode('_',$temp)));?>" class="caseBox noZ     <?php if($pram[$i]==$a['gaid']){ ?>checked<?php } ?>">
								<span class="rect"><i>√</i></span>
								<span class="case"><?php echo $a['attr_value'];?></span>
							</a>
						<?php }?>
					</div>
				</div>
				<?php $i++;?>
			<?php }?>
			<!--<div class="filCase price">
				<span class="caseTitle">价格：</span>
				<div class="op ">
					<a href="javascript:;" class="caseBox"><span class="case">￥0-300</span></a>
					<a href="javascript:;" class="caseBox"><span class="case">￥300-600</span></a>
					<a href="javascript:;" class="caseBox"><span class="case">￥600-1000</span></a>
					<a href="javascript:;" class="caseBox"><span class="case">￥1000-2000</span></a>
					<a href="javascript:;" class="caseBox"><span class="case">￥2000以上</span></a>
				</div>
			</div>-->
			
			<div class="moreFilter">
				<a>更多选项</a>
			</div>
			<!--商品排序框-->
			<!--<div class="sort">
				<a href="javascript:;">最新<i></i></a>
				<a href="javascript:;">价格<i></i></a>
				<a href="javascript:;">折扣<i></i></a>
				<a href="javascript:;" ><span href="" class="rect"><i>√</i></span>新品<i></i></a>
				<a href="javascript:;" ><span href="" class="rect"><i>√</i></span>打折<i></i></a>
				<a href="javascript:;"><span href="" class="rect"><i>√</i></span>限量<i></i></a>
			</div>-->
		</div>
		<!--商品筛选区域结束-->
		
		<!--商品展示区域开始-->
		<div class="goodsBox">
			<!--每个商品-->
			    <?php if(empty($listData)){ ?>
				<h3>没有找到符合条件的商品</h3>
			<?php }else{ ?>
				<?php foreach ($listData as $k=>$v){?>
					<div class="goods">
						<a href="<?php echo U('Content/index',array('gid'=>$v['gid']));?>" class="goodsImg">
							<img src="http://localhost/YouHuoShop/<?php echo $v['list_img'];?>"/>
							<!--加over显示-->
							    <?php if($v['store']<500){ ?>
								<p class="over">即将售罄</p>
							<?php } ?>
							<!--加sale、new class显示-->
								<span class="new">SALE</span>
						</a>
						<div class="goodsInfo">
							<a href="<?php echo U('Content/index',array('gid'=>$v['gid']));?>"><?php echo $v['gname'];?></a>
							<a href=""><?php echo $v['bname'];?></a>
							<p>
								<!--有class才显示-->
								<span class="oldprice">￥<?php echo $v['market_price'];?></span>
								<span class="price">￥<?php echo $v['shop_price'];?></span>
							</p>
						</div>
						<div class="goodsPopbox">
							<a href="<?php echo U('Content/index',array('gid'=>$v['gid']));?>" class="thumb"><img src="http://localhost/YouHuoShop/<?php echo $v['list_img'];?>" alt="" /></a>
						</div>
					</div>
				<?php }?>
				<!--每个商品结束-->
			<?php } ?>
			
		</div>
		<!--商品展示区域结束-->
		
		<!--分页-->
		
		<div class="page">
			<span class="pageData">1 - <?php echo $pageData['max'];?> / 共<?php echo $pageData['totle'];?>件商品</span>
			<span class="pageInfo">
			<?php echo $page;?>
			</span>
			
			<!--<span class="pageInfo">
				<a href=""><上一页</a>
				<a href="">1</a>
				<a href="" class="checked">2</a>
				<a href="">3</a>
				<a href="">4</a>
				<a href="">5</a>
				...
				<a href="">28</a>
				<a href="">下一页></a>
			</span>-->
		</div>
		
		<!--最近游览-->
		<div class="historyLook">
			<p class="title">最近浏览的商品</p>
			<div class="myHistory">
				<div class="goods">
					<a href="" class="goodsImg">
						<img src="http://localhost/YouHuoShop/Static/Index/images/goods/1.jpg"/>
					</a>
					<div class="goodsInfo">
						<a href="">DUNKELVOLK 满版花朵衬衫</a>
						<a href="">DUNKELVOLK</a>
						<p>
							<!--有class才显示-->
							<span class="oldprice">￥458</span>
							<span class="price">￥299</span>
						</p>
					</div>
				</div>
				
				
			</div>
		</div>
		<!--最近游览结束-->
	</div>
	<!--右侧商品区域结束-->
</div>
<!---------------商品展示区域结束 --------------->



<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>

<link rel="stylesheet" type="text/css" href="http://localhost/YouHuoShop/Static/Index/style/foot.css"/>
	
<!---------------底部区域开始------------>	
<div id="footBox">
	<div class="foot">
		<div class="top">
			<p class="bz">	
				<span class="red">100%</span>
				<span class="white">品牌授权正品</span>
			</p>
			<p class="sh">
				<span class="red">7天</span>
				<span class="white">无理由退换货</span>
			</p>
			<p class="dh">
				<span class="white">客服电话</span>
				<span class="red">400-889-9646</span>
				<span class="white">09:00-22:30(周一至周日)</span>
			</p>
		</div>
		<div class="list">
			<ul>
				<li ><a class="title" href="">新手指南</a></li>
				<li><a href="">新用户注册</a></li>
				<li><a href="">会员登录</a></li>
				<li><a href="">订购流程</a></li>
				<li><a href="">交易须知</a></li>
			</ul>
			<ul>
				<li ><a class="title" href="">付款方式</a></li>
				<li><a href="">支付方式</a></li>
				<li><a href="">常见支付问题</a></li>
				<li><a href="">如何办理退款</a></li>
				<li><a href="">发票制度说明</a></li>
			</ul>
			<ul>
				<li ><a class="title" href="">配送方式</a></li>
				<li><a href="">配送时间及范围</a></li>
				<li><a href="">订单的拆分</a></li>
				<li><a href="">商品验收与签收</a></li>
			</ul>
			<ul>
				<li ><a class="title" href="">售后服务</a></li>
				<li><a href="">如何办理退换货</a></li>
				<li><a href="">退换货政策</a></li>
				<li><a href="">在线客服</a></li>
			</ul>
			
			<ul>
				<li ><a class="title" href="">帮助中心</a></li>
				<li><a href="">找回密码</a></li>
				<li><a href="">常见问题</a></li>
				<li><a href="">谨防诈骗</a></li>
			</ul>
			<ul>
				<li ><a class="title" href="">优惠政策</a></li>
				<li><a href="">VIP会员制度说明</a></li>
				<li><a href="">YOHO币</a></li>
				<li><a href="">优惠券</a></li>
				<li><a href="">兑换礼品卡</a></li>
			</ul>
		</div>
		
		<div class="bottom">
			<div class="left">
				<img src="http://localhost/YouHuoShop/Static/Index/images/credit-flag3.png" alt="" />
				<img src="http://localhost/YouHuoShop/Static/Index/images/isc2.png" alt="" />
			</div>
			<div class="right">
				<p class="con">
					<a href="">返回首页</a>
					<span>|</span>
					<a href="">YOHO!有货</a>
					<span>|</span>
					<a href="">新力传媒</a>
					<span>|</span>
					<a href="">联系我们</a>
					<span>|</span>
					<a href="">商家入驻</a>
					<span>|</span>
					<a href="">隐私条款</a>
					<span>|</span>
					<a href="">友情链接</a>
				</p>
				<p>CopyRight © 2007-2016 南京新与力文化传播有限公司 苏ICP备09011225号 NewPower Co. 版权所有 经营许可证编号：苏B2-20120395
</p>
			</div>
		</div>
		
	</div>
</div>	
<!---------------底部区域结束------------>
	
</body>
</html>
